package com.twu.biblioteca;

/**
 * Created by tinamt on 7/23/14.
 */
public class ViewCustomerDetails implements Action {
    private Library library;
    LoginManager loginManager;

    ViewCustomerDetails(Library library, LoginManager loginManager) {

        this.library = library;
        this.loginManager = loginManager;
    }

    public void execute() throws Exception {
        System.out.println("Name\t\t\tEmail ID\t\t\tPhone Number");
        System.out.println(library.findCustomer(loginManager.currentUser).getCustomerDetails());
    }

    @Override
    public String printActionName() {
        return "View Customer Details";
    }
}
